<div class="box_right">
	<h1>编辑油枪</h1>
	<div class="pro_box layui-form">
        <div class="layui-form-item">
			<div class="layui-inline" style="width: 100%;">
				<!-- PAGE CONTENT BEGINS -->
				<form id="usrform" action="<?php echo base_url()."gasstation/oilgun/edit_oilgun/".$oilgun->id;?>" method="post">
				<input type="hidden" name="id" value="<?php if (isset($oilgun->id))echo $oilgun->id;?>">
				<input type="hidden" name="gm_id" value="<?php echo $gm_id;?>">
				    <div class="box-body" style="display: inline-block;width: 100%">
				        <div class="form-group col-xs-6">
				            <label>油枪名称：</label>
				            <input name="oilgun_name" type="text" class="layui-input" placeholder="输入 ..." value="<?php if (isset($oilgun->oilgun_name))echo $oilgun->oilgun_name;?>" datatype="*" nullmsg="请输入油枪名称！">
			            </div>
                    </div>           
                    <div class="clearfix form-actions">
						<div class="col-md-offset-3 col-md-9">
							<button id="btnSubmit" class="btn btn-info" type="submit">
								<i class="icon-ok bigger-110"></i>
								保存
							</button>
							&nbsp; &nbsp; &nbsp;
							<a class="btn btn-warning" href="<?php echo base_url()."gasstation/oilgun/index/" .$gm_id;?>">
								<i class="icon-undo bigger-110"></i>
								返回
							</a>
						</div>
					</div>
				</form>
			</div>
		</div><!-- /.row -->
	</div><!-- /.page-content -->
</div><!-- /.main-content -->
<script>
//Demo
layui.use(['form','element','laydate'], function(){
  var form = layui.form,
  	element = layui.element,
  	laydate = layui.laydate;
});
//验证表单
$(function(){
    $.Tipmsg.r=null;
    $("#usrform").Validform({
        tiptype:function(msg){
            layer.msg(msg);
        },
        tipSweep:true,
        ajaxPost:false
    });
})
</script>